-
Notifications
You must be signed in to change notification settings - Fork 905
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add changelog generation script #4386
Add changelog generation script #4386
Conversation
Signed-off-by: Matt Provost <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #4386 +/- ##
=======================================
Coverage 66.15% 66.15%
=======================================
Files 3314 3314
Lines 63907 63907
Branches 9963 9963
=======================================
Hits 42277 42277
Misses 19184 19184
Partials 2446 2446
Flags with carried forward coverage won't be shown. Click here to find out more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few high level comments here:
- This change should not wipe out the existing changelog file, but add onto it. Only the unreleased section should be removed, but that can be a manual action too. Its safe to assume that we will do a one time cleanup of the changelog to prep it for the new system, if we can avoid it the better, but its not necessary.
- The new changelog format also seems to include the tag and release date, lets follow this style too
- As per the proposal, once the changelog is generated, the associated changeset files should be deleted too.
for (const [sectionKey, entries] of Object.entries(fragmentYaml)) { | ||
if (!SECTION_KEYS.includes(sectionKey)) { | ||
// eslint-disable-next-line no-console | ||
console.warn(`Unknown section ${sectionKey}. Ignoring`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IF we encounter an unknown section I thin id like to be warned more explicitly. We dont want to miss something from the changelog because we missed a warning.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it should blow up with errors and exit without actually modifying the changelog?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nah it can modify, we have git histories to revet the change if necessary.
@BSFishy Due to an extended period without updates, we're going to close this issue for now. We appreciate your contribution and understand that priorities and availability can change. Please feel free to reopen this issue when you have the opportunity to revisit it. Thank you for your understanding. |
Description
Implements the changelog generation script as defined in the changesets proposal. To activate it, run
yarn changelog:generate
.Currently, this PR is a draft. I am still working on it to make sure it adheres to the proposal. I created it as a draft so I can share it with other team members to get feedback as I'm developing. If you have some feedback in its current state, feel free to share it as a comment.
Issues Resolved
Implements changelog generator described in opensearch-project/.github#156
Testing the changes
Added sample changesets and ran
yarn changelog:generate
.Check List
yarn test:jest
yarn test:jest_integration
yarn test:ftr